public class Guichet extends Thread{
	private boolean guichetOccupe;
	
	public static int IMPRESSION_TICKET = 1000;
	
	public Guichet ()
	{
		guichetOccupe = false;
	}
	
	public boolean getGuichetOccupe()
	{
		return this.guichetOccupe;
	}

	public void run()
	{
		while(true)
		{ 
			try {Thread.sleep(1000);} catch(InterruptedException e) {}
		}
	}
	  
	public void imprimerTicket  
	{
		guichetOccupe = true;
		try {Thread.sleep(IMPRESSION_TICKET);} catch(InterruptedException e) {}
		System.out.println("Voyageurs vient de prendre ticket");
		guichetOccupe = false; 
	}
	
}







//		while(guichetOccupe)
//		{
//			try {wait();} catch(InterruptedException e){}
//		}
//		notify();